<%@page contentType="text/html; charset=UTF-8"%>
<%@taglib uri="/WEB-INF/struts-tags.tld" prefix="s"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>票易信息管理系统</title>
<link rel="stylesheet" href="/css/admin.css" type="text/css"/>
<script type="text/javascript" src="/js/jquery-1.6.1.min.js"></script>
</head>
<body leftmargin="2" topmargin="2">
<s:form id="create" action="admin_orderinfo" onsubmit="VF_orderinfoflag();return false;">
<s:hidden name="action" />
<s:hidden name="id" />
 <fieldset><legend>
 <s:if test="%{action=='doupdate'}">修改订单信息</s:if>
 </legend>
 <table width="100%" border="0" align="center" cellpadding="3" cellspacing="1">
  <COLGROUP>
  <COL width="100" />
  <COL width="*" />
  	<tr class="tdbg2"> 
      <td align="right">订单名称：</td>
      <td><s:property value="orderInfo.orderName"/> <font color="#0066CC"><b>订单号:</b></font><s:property value="orderInfo.orderNO"/> <font color="#0066CC"><b>订单创建时间:</b></font><s:date name="orderInfo.addTime" format="yyyy年MM月dd日 HH:mm:ss"/></td>
    </tr>
    <tr class="tdbg3"> 
      <td align="right">订单用户：</td>
      <td><s:property value="orderInfo.userInfo.account"/> 手机号:<s:property value="orderInfo.userInfo.mobile"/></td>
    </tr>
  	<tr class="tdbg2"> 
      <td align="right" >订单状态：</td>
      <td><s:select list="orderStatusList" name="orderStatus" id="orderStatus" listKey="key" listValue="value"></s:select> <font color="#0066CC"><b>订单确认时间:</b></font><s:date name="orderInfo.confirmTime" format="yyyy年MM月dd日 HH:mm:ss"/></td>
    </tr>
    <tr class="tdbg3"> 
      <td align="right">配送信息：</td>
      <td>
      	<s:property value="orderInfo.province"/> <s:property value="orderInfo.city"/> <s:property value="orderInfo.district"/> <s:property value="orderInfo.address"/><br />
      	<font color="#0066CC"><b>收件人:</b></font><s:property value="orderInfo.consignee"/><br />
      	<font color="#0066CC"><b>邮编:</b></font><s:property value="orderInfo.zipcode"/> 手机:<s:property value="orderInfo.mobile"/> 邮箱：<s:property value="orderInfo.email"/><br />
      	<font color="#0066CC"><b>配送名称:</b></font><s:property value="orderInfo.shippingName"/>
      </td>
    </tr>
    <tr class="tdbg2"> 
      <td align="right" >配送状态：</td>
      <td><s:select list="shippingStatusList" name="shippingStatus" id="shippingStatus" listKey="key" listValue="value"></s:select> <font color="#0066CC"><b>订单支付时间:</b></font><s:date name="orderInfo.shippingTime" format="yyyy年MM月dd日 HH:mm:ss"/></td>
    </tr>
    <tr class="tdbg3"> 
      <td align="right">配送号：</td>
      <td><s:textfield id="shippingNO" name="shippingNO" size="20"/></td>
    </tr>
    <tr class="tdbg3"> 
      <td align="right">支付信息：</td>
      <td><s:property value="orderInfo.payName"/>  <font color="#0066CC"><b>商品总金额:</b></font><s:property value="orderInfo.goodsAmount"/><font color="#0066CC"><b>配送金额:</b></font><s:property value="orderInfo.shippingAmount"/><font color="#0066CC"><b>总共费用:</b></font><s:property value="orderInfo.orderAmount"/></td>
    </tr>
    <tr class="tdbg3"> 
      <td align="right">支付状态：</td>
      <td><s:select list="payStatusList" name="payStatus" id="payStatus" listKey="key" listValue="value"></s:select> <font color="#0066CC"><b>订单支付时间:</b></font><s:date name="orderInfo.payTime" format="yyyy年MM月dd日 HH:mm:ss"/></td>
    </tr>
     <tr class="tdbg3">
      <td colspan="2" align="center"><s:submit value="提交"/></td>
    </tr>
</table></fieldset>
</s:form>
<fieldset><legend>订单信息-详细票信息：</legend>
<table width="100%" border="0" align="center" cellpadding="3" cellspacing="1">
  <COLGROUP>
  <COL width="*" />
  <COL width="100" />
  <tr style="font-weight: bold;" align="center" class="tdbg2"> 
    <td>商品名</td>
    <td>场次名称</td>
    <td>价格名称</td>
    <td>购买数量</td>
  </tr>
<s:iterator id="g" value="%{orderInfo.orderGoodses}">
    <tr class="tdbg3" align="center"> 
      <td><s:property value="#g.goodsName"/></td>
      <td><s:property value="#g.dailyName"/></td>
      <td><s:property value="#g.priceName"/></td>
      <td><s:property value="#g.goodsNumber"/></td>
    </tr>
</s:iterator>
</table>
</fieldset>
<script type="text/javascript">
function VF_orderinfoflag(){ 
    var errMsg = "";
    if ($('#orderStatus').val() == -1){
        errMsg = "请选择订单状态！";
    }
    if ($('#shippingStatus').val() == -1){
        errMsg = "请选择配送状态！";
    }
    if (errMsg != ""){
        alert(errMsg);
    }else{
		document.getElementById('create').submit();
	}
}
</script>
</body>
</html>
